package cn.edu.hnit.javaee.experiments.experiment06.service;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

import cn.edu.hnit.javaee.experiments.experiment06.dao.VideoRecordDao;
import cn.edu.hnit.javaee.experiments.experiment06.model.VideoRecordPOJO;

public class VideoRecordServiceImpl implements IVideoRecordService{

	private VideoRecordDao videoRecordDao;

	public List<VideoRecordPOJO> getPage(int page){
		int pageSize = 8;
		int currentPageNo = (page%2)*pageSize;
		Map<String,Object> params = new HashMap<String,Object>();
		params.put("currentPageNo",currentPageNo);
		params.put("pageSize",pageSize);
		return videoRecordDao.getPage(params);
	}
}
